//
//  BSAddPathViewController.m
//  BaiSiBuDeJie
//
//  Created by 王位 on 8/31/16.
//  Copyright © 2016 tsaievan. All rights reserved.
//

#import "BSAddPathViewController.h"

#import "AddToolBarView.h"

@interface BSAddPathViewController ()
@property (weak, nonatomic) IBOutlet UITextView *pathTextView;

@property (weak, nonatomic) IBOutlet UITextField *pathText;
@end

@implementation BSAddPathViewController


+(instancetype)addPathViewController
{
    UIStoryboard * storyboard =[UIStoryboard storyboardWithName:@"BSAddPathViewController" bundle:nil];
    
    BSAddPathViewController * viewC = storyboard.instantiateInitialViewController;
    
    return viewC;
}
//- (IBAction)didClicCancel:(id)sender {
//    
//    [self.navigationController popViewControllerAnimated:YES];
//    
//}

- (void)viewDidLoad {
    [super viewDidLoad];
    
    AddToolBarView * view = [AddToolBarView addToolBarView];
    
    self.pathText.inputAccessoryView = view;
    
    self.pathTextView.inputAccessoryView = view;
    
    [self.pathTextView becomeFirstResponder];
    
}

-(void)touchesBegan:(NSSet<UITouch *> *)touches withEvent:(UIEvent *)event
{
    [self.pathTextView endEditing:YES];
    
    [self.pathText endEditing:YES];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
